<?php

namespace App\Http\Requests;

use Illuminate\Foundation\Http\FormRequest;

class ManagerFeedbackRequest extends BasicRequest
{
    /**
     * Determine if the user is authorized to make this request.
     *
     * @return bool
     */
    public function authorize()
    {
        return true;
    }

    /**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
    public function rules()
    {
        return [
            //
			'uid'		=> 'required|numeric',
			'star'		=> 'required|numeric|min:1|max:5',
			'tags'		=> 'json',
//			'comment'	=> 'required',
        ];
    }
    
    public function messages(){
    	return [
    		'uid.required'			=> '被投诉人参数必传',
			'uid.numeric'			=> '被投诉人参数格式错误',
			'star.required'			=> '请选择服务评分',
			'star.numeric'			=> '服务评分参数格式错误',
			'star.min'				=> '请选择服务评分',
			'star.max'				=> '服务评分等级超出最大限制',
			'tags.json'				=> '印象标签参数格式错误',
//			'comment.required'		=> '请填写评价内容',
		];
	}
}
